﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace HiUpdateTools.Core
{
    public class DeployConfig : XmlSerializationBase
    {
        public List<ProjectConfig> Projects { get; set; }
        public List<VersionInfo> ChangeLogs { get; set; }
   
        public string ApplicationName { get; set; }
        public ApplicationType DeployType { get; set; }
        public string Version { get; set; }

        public PathType ServerPathType { get; set; }
        public string ServerPath { get; set; }
        public bool ServerAnonymous { get; set; }
        public string ServerUserName { get; set; }
        public string ServerPassword { get; set; }






    }
    public enum ApplicationType
    {

        WinApplication,
        Service,
        WebApplication,
        AndroidApplication

    }
    public enum PathType
    {

        http,
        https,
        ftp,
        ftps,
        file
    }
    public class ProjectConfig
    {
        public ProjectConfig() {
            WriteVerion = false;
        
        }

        public string Name { get; set; }
        public bool WriteVerion { get; set; }

    }

    public class VersionInfo
    {
        public override string ToString()
        {
            return Version + " - " + Date;
        }
        public string Info { get; set; }
        public string Version { get; set; }
        public DateTime Date { get; set; }

    }
}
